package com.wjc.train.business.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.wjc.train.business.req.SkTokenQueryReq;
import com.wjc.train.business.req.SkTokenSaveReq;
import com.wjc.train.business.resp.SkTokenQueryResp;

import java.util.Date;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author Guessed
 * @since 2023-09-01
 */
public interface ISkTokenService  {

  /**
     * 保存或修改
     * @param sktokenSaveReq
     */
    void save(SkTokenSaveReq sktokenSaveReq);

    /**
     * 分页查询
     * @param page
     * @param sktokenQueryReq
     * @return
     */
    IPage<SkTokenQueryResp> queryList(IPage<SkTokenQueryResp> page, SkTokenQueryReq sktokenQueryReq);

    /**
     * 删除
     * @param id
     */
    void delete(Long id);

  /**
   * 生成令牌信息
   * @param trainDate
   * @param trainCode
   */
  void genDaily(Date trainDate, String trainCode);

  boolean vaildateSkToken(Date trainDate, String trainCode,Long memberId);

}
